package com.hg.chapter931.message;

import org.springframework.jms.annotation.JmsListener;
import org.springframework.stereotype.Component;

//注入目的地
@Component
public class MyDestination {

    @JmsListener(destination = "my-destination")
    public void receiveMessage(String message) {
        System.out.println("收到消息" + message);
    }
}
